package enemies;

import java.awt.Dimension;
import java.awt.geom.Point2D;
import java.util.ArrayList;

import javax.swing.ImageIcon;

import projectiles.Bullet;
import projectiles.Projectile;

public class Tank extends MobileEnemy{
	
	private static final ImageIcon image = new ImageIcon(Tank.class.getResource("../images/tankbody.gif"));
	private static final ImageIcon deviceImage = new ImageIcon(Tank.class.getResource("../images/tank-cannon.gif"));
	private static final ImageIcon nukedImage2 = new ImageIcon(Tank.class.getResource("../images/nuked/tank-cannon.gif"));
	
	public Tank(ArrayList<Point2D.Double> route, Point2D.Double position, int health, int speed, int damageMultiplier) {
		super(route, position, health, new Dimension(image.getIconWidth(), image.getIconHeight()), image, 800, 350, speed, damageMultiplier, deviceImage, 0, nukedImage2 );
		this.nukedImage = "images/nuked/tankbody.gif";
	}
	
	public Projectile shoot(){
		updateFirerate();

		return new Bullet( this, getPosition(), deviceAngle, aimAtTower.getMiddle());
	}

}
